package com.ruoyi.service.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.service.mapper.ServiceAddressMapper;
import com.ruoyi.service.domain.ServiceAddress;
import com.ruoyi.service.service.IServiceAddressService;

/**
 * 服务地址Service业务层处理
 * 
 * @author ZDL
 * @date 2024-11-27
 */
@Service
public class ServiceAddressServiceImpl implements IServiceAddressService 
{
    @Autowired
    private ServiceAddressMapper serviceAddressMapper;

    /**
     * 查询服务地址
     * 
     * @param addressId 服务地址主键
     * @return 服务地址
     */
    @Override
    public ServiceAddress selectServiceAddressByAddressId(Long addressId)
    {
        return serviceAddressMapper.selectServiceAddressByAddressId(addressId);
    }

    /**
     * 查询服务地址列表
     * 
     * @param serviceAddress 服务地址
     * @return 服务地址
     */
    @Override
    public List<ServiceAddress> selectServiceAddressList(ServiceAddress serviceAddress)
    {
        return serviceAddressMapper.selectServiceAddressList(serviceAddress);
    }

    /**
     * 新增服务地址
     * 
     * @param serviceAddress 服务地址
     * @return 结果
     */
    @Override
    public int insertServiceAddress(ServiceAddress serviceAddress)
    {
        return serviceAddressMapper.insertServiceAddress(serviceAddress);
    }

    /**
     * 修改服务地址
     * 
     * @param serviceAddress 服务地址
     * @return 结果
     */
    @Override
    public int updateServiceAddress(ServiceAddress serviceAddress)
    {
        return serviceAddressMapper.updateServiceAddress(serviceAddress);
    }

    /**
     * 批量删除服务地址
     * 
     * @param addressIds 需要删除的服务地址主键
     * @return 结果
     */
    @Override
    public int deleteServiceAddressByAddressIds(Long[] addressIds)
    {
        return serviceAddressMapper.deleteServiceAddressByAddressIds(addressIds);
    }

    /**
     * 删除服务地址信息
     * 
     * @param addressId 服务地址主键
     * @return 结果
     */
    @Override
    public int deleteServiceAddressByAddressId(Long addressId)
    {
        return serviceAddressMapper.deleteServiceAddressByAddressId(addressId);
    }
}
